package com.project.controller;

import com.project.bean.CountBean;
import com.project.service.ICountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author lyl
 * description:
 */
@RequestMapping(value = "count")
@RestController
public class CountController {
    @Autowired
    private ICountService iCountService;

    @RequestMapping("countByMonth")
    public List<CountBean> count(String year) {
        return iCountService.getInfoByProductId(year);
    }
}
